package com.ming.transaction.controller;


import com.ming.transaction.common.Result;
import com.ming.transaction.entity.Order;
import com.ming.transaction.service.IOrderService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author 陈仕健
 * @since 2023-05-14
 */
@Api(tags = "订单管理")
@RestController
@RequestMapping("/order")
public class OrderController {

    @Resource
    private IOrderService orderService;

    @PostMapping
    @ApiOperation("订单提交")
    private Result inputOrder(@RequestBody Order order){
        return orderService.addOrder(order);
    }


}

